﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ListLichCongTacs.aspx.cs" Inherits="DATN.ListLichCongTacs" MasterPageFile="~/Share/BackEndMaster.Master" %>

<asp:Content ID="headContent" runat="server" ContentPlaceHolderID="ContentHeader">
    Lich Cong Tac
</asp:Content>
<asp:Content ID="contentHolder" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="content">
        <div id="titleContent" style="text-align: center;">Lịch Công Tác</div>
        <div style="text-align: center;">(Tuần từ
            <asp:Label ID="FromWeek" runat="server"></asp:Label>
            đến
            <asp:Label ID="ToWeek" runat="server"></asp:Label>
            )</div>
        <asp:Button ID="btnTuanTruoc" runat="server" Text="Tuần trước" OnClick="btnTuanTruoc_Click" /><asp:Button ID="btnTuanSau" runat="server" Text="Tuần sau" OnClick="btnTuanSau_Click" />

        <table border="1" style="width: 600px;">
            <tr style="text-align: center; background-color: brown; font-weight: bold">
                <td colspan="2">Thời gian</td>
                <td>Nội dung</td>
                <td>Thành Phần </td>
                <td>Chủ trì </td>
                <td>Địa điểm</td>
                <td>Ghi Chú</td>
            </tr>
            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursMo %>">Thứ 2
                    <asp:Label ID="MoDate" runat="server"></asp:Label>
                </td>
                <%if (_hoursMo > 1)
                  { %>
                <asp:DataList ID="DataListMonday" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                            <td><%# Eval("Gio_bat_dau") %>h</td>
                            <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>

                        </tr>
                    </ItemTemplate>
                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>

            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursTu %>">Thứ 3
                    <asp:Label ID="TuDate" runat="server"></asp:Label></td>
                <%if (_hoursTu > 1)
                  { %>
                <asp:DataList ID="DataListTu" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                            <td><%# Eval("Gio_bat_dau") %>h</td>
                            <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>

                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>


            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursWe %>">Thứ 4
                    <asp:Label ID="WeDate" runat="server"></asp:Label></td>
                <%if (_hoursWe > 1)
                  { %>
                <asp:DataList ID="DataListWe" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                           <td><%# Eval("Gio_bat_dau") %>h</td>
                           <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>

                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>


            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursTh %>">Thứ 5
                    <asp:Label ID="ThDate" runat="server"></asp:Label></td>
                <%if (_hoursTh > 1)
                  { %>
                <asp:DataList ID="DataListTh" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                           <td><%# Eval("Gio_bat_dau") %>h</td>
                            <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>
                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>


            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursFr %>">Thứ 6
                    <asp:Label ID="FrDate" runat="server"></asp:Label></td>
                <%if (_hoursFr > 1)
                  { %>
                <asp:DataList ID="DataListFr" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                           <td><%# Eval("Gio_bat_dau") %>h</td>
                            <a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>

                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>


            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursSa %>">Thứ 7
                    <asp:Label ID="SaDate" runat="server"></asp:Label></td>
                <%if (_hoursSa > 1)
                  { %>
                <asp:DataList ID="DataListSa" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                            <td><%# Eval("Gio_bat_dau") %>h</td>
                            <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>

                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>


            <tr style="text-align: center;">
                <td style="width: 40px; font-weight: bold" rowspan="<%=_hoursSu %>">Chủ Nhật
                    <asp:Label ID="SuDate" runat="server"></asp:Label></td>
                <%if (_hoursSu > 1)
                  { %>
                <asp:DataList ID="DataListSu" runat="server" HorizontalAlign="Center" Border="1" RepeatLayout="Flow" RepeatDirection="Vertical">
                    <ItemTemplate>
                        <tr>
                            <td><%# Eval("Gio_bat_dau") %>h</td>
                            <td><a style="color: lavender" href='UpdateLichCT.aspx?id=<%# Eval("Ma_ID") %>'><%# Eval("Noi_dung") %> </a></td>
                            <td><%# Eval("Thanh_phan") %></td>
                            <td><%# Eval("Nguoi_chu_tri") %></td>
                            <td><%# Eval("Dia_diem") %> </td>
                            <td><%# Eval("Ghi_chu") %></td>
                        </tr>
                    </ItemTemplate>

                </asp:DataList>
                <%}
                  else
                  { %>

                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>
                <td></td>

                <% } %>
            </tr>
        </table>
    </div>
</asp:Content>
